import axios from '@/request/http'
import { commonOutDTO } from '@/api/common.d'

export default class bydmService {
  // 左边
  static queryLeftMenu(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/query', data)
  }
  // 根据lbbm查询分类代码树
  static queryLbTable(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/queryBmLb', data)
  }
  // 根据lbbm查询分类代码树
  static queryTable(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/queryBmLb', data)
  }
  // 新增分类代码类别
  static addFldmlb(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/add', data)
  }
  // 删除
  static deletFldmlb(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/delete', data)
  }
  // 查询单个
  static serchSingNode(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/get', data)
  }
  // 修改单个
  static changeSingNode(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/update', data)
  }
  // 检查类别编码是否可用
  static checkLbbm(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldmlb/checkLbbm', data)
  }
  // 要号
  static yaohao(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/getDm', data)
  }
  // 添加分类代码弹框
  static addDiaApi(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/add', data)
  }
  // 修改
  static changeDiaApi(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/update', data)
  }
  // 删除
  static deletDiaApi(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/delete', data)
  }
  // 获取代码
  static getFldm(data: any): Promise<commonOutDTO<any>> {
    return axios.post('/dm/fldm/get', data)
  }
}
